export default function({
	route,
	store,
	req,
	res,
	redirect
}) {
	// If the user is not authenticated
	let path;
	//在服务端
	if (process.server) {
		path = req.originalUrl;
	}
	//在客户端判读是否需要登陆
	if (process.client) {
		path = route.path;
	}
	if(!store.state.userInfo){
		return redirect('/login?redirectUrl='+path)
	}
}
